package com.juyu.miliao.api.dao.mysql;

import java.util.HashMap;
import java.util.Map;
import org.apache.ibatis.session.SqlSession;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.juyu.miliao.common.dataSource.tool.operate.Operate;

@Repository
public class UserLineDao {
	@Autowired
	private SqlSession sqlSession;

	@Operate("strategy('byUserId', #userId)")
	public int addLineTime(long userId, long time, String createDate){
		Map<String, Object> params = new HashMap<>();
		params.put("userId", userId);
		params.put("time", time);
		params.put("createDate", createDate);
		return sqlSession.update("addLineTime", params);
	}
}
